Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate to new SwiftUI navigation types and make ChatChannel non-optional #31

Merged
merged 6 commits into from
Aug 3, 2024

Conversation

fwcd
Copy link
Owner

@fwcd fwcd commented Aug 3, 2024

This migrates to iOS 16's navigation types (NavigationSplitView and NavigationStack), along with representing the global channel with ChatChannel.global instead of nil, since this plays better with the new navigation types1 and is better design anyway. Unfortunately, it is also a breaking change in the protocol, since attaching a channel to messages is now mandatory, since the protocol is considered unstable, however, this shouldn't be too big of an issue.

Footnotes

  1. Otherwise the navigation links will appear grayed out

fwcd added 6 commits August 3, 2024 20:02
The global channel is now ChatChannel.global rather than nil.
Representing this without an optional has a few advantages, namely that
it plays better with SwiftUI list selections (which appear grayed out if
nil, despite this being a semantically valid value in our previous
model) and that it lets us avoid nested optionals.
@fwcd fwcd merged commit 25d6a67 into main Aug 3, 2024
11 checks passed
@fwcd fwcd deleted the migrate-navigation branch August 3, 2024 19:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant